<template>
  <div>
    <el-dialog :class="'el-dialog-theme3'" append-to-body draggable :close-on-click-modal="false"
      v-model="open" title="方案信息" fullscreen @close="closedDialog">
      <schemeDetails :projectId="props.params.projectId" :isdisabel="true" ref="schemeDetailsRef" />
      <template #footer>
        <div class="dialog-footer">
          <el-button type="danger" @click="confirm">确定</el-button>
        </div>
      </template>
    </el-dialog>
  </div>
</template>

<script setup>
import schemeDetails from "./component/schemeDetails.vue";
import bus from "@/utils/eventBus";


const schemeDetailsRef = ref(null)
const open = ref(true)

const props = defineProps({
  params: {
    type: Object,
  },
});


const emit = defineEmits(["closeDialog"]);
function closedDialog() {
  emit("closeDialog");
}

// 刷新
function confirm() {
  emit("closeDialog");
  bus.emit("refresh")
}
</script>
